package org.mobai.algorithm.db;

import org.apache.shardingsphere.api.sharding.standard.PreciseShardingAlgorithm;
import org.apache.shardingsphere.api.sharding.standard.PreciseShardingValue;
import org.mobai.util.ShardingUtils;

import java.util.Collection;
import java.util.Date;

/**
 * @author Administrator
 * @version v1.0
 * @className OrderItemPreciseShardingAlgorithm
 * @description
 * @date 2024/5/11 星期六 14:29
 **/
public class OrderItemDbPreciseShardingAlgorithm implements PreciseShardingAlgorithm<Date> {
    @Override
    public String doSharding(Collection<String> collection, PreciseShardingValue<Date> preciseShardingValue) {
        return ShardingUtils.quarterDbPreciseSharding(collection, preciseShardingValue);
    }
}
